| 123456789101112131415161718192021222324252627282930 |
- <template>
- <main>
- <LayoutContainer>
- <UiLoadingPanel v-if="pending" />
- <div v-else>
- <LayoutParametersCycleEditForm :cycle="cycle" />
- </div>
- </LayoutContainer>
- </main>
- </template>
- <script setup lang="ts">
- import {useEntityFetch} from "~/composables/data/useEntityFetch";
- import Cycle from "~/models/Education/Cycle";
- const { fetch } = useEntityFetch()
- const route = useRoute()
- if (!route.params.id || isNaN(route.params.id as any)) {
- throw new Error('no id found')
- }
- const id: number = parseInt(route.params.id as string)
- const { data: cycle, pending } = fetch(Cycle, id)
- </script>
- <style scoped lang="scss">
- </style>
|